{foreach from=$entries item="item" name="categories"}
    
    <a href="photo/{$item.url}" class="white">
        {$item.name|escape|utf8_lowercase}
    </a> {if not $smarty.foreach.categories.last}|{/if}
    
{/foreach}